import request from '@/utils/request'

export function getClubUserList(data) {
  return request({
    url: '/user/getClubUserList',
    method: 'post',
	data
  })
}


export function getUserArticle(data) {
  return request({
    url: '/article/getUserArticle',
    method: 'post',
	data
  })
}

export function getUserById(userId) {
  return request({
    url: '/audit/getUserById',
    method: 'get',
	params: {userId}
  })
}

// 获取比赛详情	
export function getRaceInfoById(raceId) {
  return request({
    url: '/race/getRaceInfoById',
    method: 'get',
	params: {raceId}
  })
}

// 获取部门信息
export function getCLubDep(clubId) {
  return request({
    url: '/user/getCLubDep',
    method: 'get',
	params: {clubId}
  })
}

// 获取职位信息
export function getAllPosts() {
  return request({
    url: '/user/getAllPosts',
    method: 'get',
  })
}

// 修改成员职位
export function insertRoleUser(data) {
  return request({
    url: '/user/insertRoleUser',
    method: 'post',
	data
  })
}

// 获取部门比赛
export function getAllAuditRace(data) {
  return request({
    url: '/race/getAllAuditRace',
    method: 'post',
	data
  })
}

// 获取所有文章
export function getAuditArticle(data) {
  return request({
    url: '/audit/getAuditArticle',
    method: 'post',
	data
  })
}

// 通过文章
export function reviewedArticle(articleId) {
  return request({
    url: '/article/reviewedArticle',
    method: 'get',
	params: {articleId}
  })
}

// 不通过文章
export function unReviewedArticle(articleId) {
  return request({
    url: '/article/unReviewedArticle',
    method: 'get',
	params: {articleId}
  })
}

// 获取参加人员名单，并且导出excel表
export function raceExcel(raceId) {
  return request({
    url: '/audit/raceExcel',
    method: 'get',
	params: {raceId}
  })
}

// 获取申请加入社团人员名单
export function getClubAuditUser(data) {
  return request({
    url: '/audit/getClubAuditUser',
    method: 'post',
	data
  })
}

// 不通过申请人员
export function isAuditUser(userApplicationId) {
  return request({
    url: '/audit/isAuditUser',
    method: 'get',
	params: {userApplicationId}
  })
}

// 通过申请人员
export function isOkAuditUser(userApplicationId) {
  return request({
    url: '/audit/isOkAuditUser',
    method: 'get',
	params: {userApplicationId}
  })
}

// 申请加入社团
export function insertClubUser(data) {
  return request({
    url: '/club/insertClubUser',
    method: 'post',
	data
  })
}

// 获取申请社团列表
export function getAuditClub(data) {
  return request({
    url: '/audit/getAuditClub',
    method: 'post',
	data
  })
}

// 申请创建社团
export function clubApplication(data) {
  return request({
    url: '/audit/clubApplication',
    method: 'post',
	data
  })
}

// 通过申请社团
export function auditClubApplication(clubApplicationId) {
  return request({
    url: '/audit/auditClubApplication',
    method: 'get',
	params: {clubApplicationId}
  })
}

// 不通过申请社团
export function auditNoClubApplication(clubApplicationId) {
  return request({
    url: '/audit/auditNoClubApplication',
    method: 'get',
	params: {clubApplicationId}
  })
}